package com.wiz.weixin.service;

import java.util.List;

import com.wiz.weixin.to.StationTO;
import com.wiz.weixin.util.PageView;
import com.wiz.weixin.vo.MemberVO;
import com.wiz.weixin.vo.ResultVO;

/**
 * 会员服务
 * @author xxy
 *
 */
public interface MemberService {

	/**
	 * 注册
	 * @param member
	 * @param code
	 * @return
	 * @throws Exception
	 */
	ResultVO register(MemberVO member,int code, StationTO stationTO) throws Exception;
	
	/**
	 * 获取该openId下的所有会员信息
	 * @param openId
	 * @return
	 * @throws Exception
	 */
	List<MemberVO> listMemberByOpenId(String openId) throws Exception;
	
	/**
	 * 获取该openId某总部下的会员信息
	 * @param openId
	 * @param hqId
	 * @return
	 */
	MemberVO getMemberByOpenId(String openId,String hqId) throws Exception;
	
	/**
	 * 账户明细列表
	 * @param hqId
	 * @param memberId
	 * @param pageNo
	 * @param pageSize
	 * @return
	 * @throws Exception
	 */
	PageView listAmountHistory(String hqId,String memberId,int pageNo,int pageSize) throws Exception;
	
	/**
	 * 验证会员密码
	 * @param memberId
	 * @param password
	 * @return
	 */
	int checkMemberPassword(String memberId,String password);
	
	/**
	 * 微信绑定账号
	 * @param memberId
	 * @param openId
	 * @return
	 */
	int bindOpenId(String hqId, String memberId, String openId);
	
	/**
	 * 填充对应hq的配置
	 * @param memberList
	 * @throws Exception
	 */
	void memberHqConfig(List<MemberVO> memberList) throws Exception;
}
